package com.yuexi.infrastructure.repository;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.yuexi.domain.bill.bo.AddBillDetailBO;
import com.yuexi.domain.repository.BillDetailRepository;
import com.yuexi.infrastructure.converter.Converter;
import com.yuexi.infrastructure.db.entity.BillDetail;
import com.yuexi.infrastructure.db.mapper.BillDetailMapper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Repository;

/**
 * @author jie
 * @date 2023/4/6 -17:01
 */
@Slf4j
@Repository
public class BillDetailRepositoryImpl extends ServiceImpl<BillDetailMapper, BillDetail> implements BillDetailRepository {

    @Override
    public void add(AddBillDetailBO bo) {
        super.save(Converter.INSTANCE.toBillDetail(bo));
    }
}
